<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html lang="zh-cn" xml:lang="zh-cn">
 <head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="DC.Type" content="topic">
  <meta name="DC.Title" content="卸载ProtectAgent（适用于Linux OS/AIX OS）">
  <meta name="DC.Format" content="XHTML">
  <meta name="DC.Identifier" content="ZH-CN_TOPIC_0000001792549964">
  <meta name="DC.Language" content="zh-cn">
  <link rel="stylesheet" type="text/css" href="public_sys-resources/commonltr.css">
  <title>卸载ProtectAgent（适用于Linux OS/AIX OS）</title>
 </head>
 <body style="clear:both; padding-left:10px; padding-top:5px; padding-right:5px; padding-bottom:5px">
  <a name="ZH-CN_TOPIC_0000001792549964"></a><a name="ZH-CN_TOPIC_0000001792549964"></a>
  <h1 class="topictitle1">卸载ProtectAgent（适用于Linux OS/AIX OS）</h1>
  <div>
   <p>卸载ProtectAgent后，<span>本产品</span>将不会对资源进行备份或恢复。</p>
   <div class="section">
    <h4 class="sectiontitle">背景信息</h4>
    <p>以下操作均以ProtectAgent的安装目录为“/opt”为例进行说明。</p>
   </div>
   <div class="section" id="ZH-CN_TOPIC_0000001792549964__section95618329544">
    <h4 class="sectiontitle">前提条件</h4>
    <p id="ZH-CN_TOPIC_0000001792549964__p11178191432914">如果在代理主机上设置了<strong id="ZH-CN_TOPIC_0000001792549964__b1217817142295">rm</strong>、<strong id="ZH-CN_TOPIC_0000001792549964__b1479094817301">cp</strong>、<strong id="ZH-CN_TOPIC_0000001792549964__b1646412133117">mv</strong>等命令需要交互式输入的别名（例如：设置<strong id="ZH-CN_TOPIC_0000001792549964__b12670182171315">mv=mv -i</strong>，<strong id="ZH-CN_TOPIC_0000001792549964__b5246558114412">mv</strong>命令默认以<strong id="ZH-CN_TOPIC_0000001792549964__b92462058164413">-i</strong>参数执行），请先取消别名设置，否则会导致卸载失败。</p>
   </div>
   <div class="section">
    <h4 class="sectiontitle">操作步骤</h4>
    <ol>
     <li><span>使用PuTTY，以系统管理员账户登录需要卸载ProtectAgent的主机。</span></li>
     <li><span>执行以下命令进入ProtectAgent软件安装目录。</span><p></p><pre class="screen">cd <em>/opt</em>/DataBackup/ProtectClient</pre> <p></p></li>
     <li><span>执行以下命令卸载软件。</span><p></p><pre class="screen">sh uninstall.sh</pre> <p>当系统回显类似如下信息时，请输入<strong>y</strong>。</p> <pre class="screen">Are you sure you want to uninstall DataBackup ProtectAgent? y/n:</pre> <p>当回显提示“DataBackup ProtectAgent has been uninstalled successfully.”，表示卸载成功。</p> <p></p></li>
    </ol>
    <ol start="4">
     <li><span>如果该主机后续会再次安装ProtectAgent，则请执行以下命令删除主机的<span class="uicontrol">“/etc/HostSN/HostSN”</span>文件。否则，请跳过本步骤。</span><p></p><pre class="screen">rm -rf /etc/HostSN/HostSN</pre> <p></p></li>
    </ol>
    <ol start="5">
     <li id="ZH-CN_TOPIC_0000001792549964__zh-cn_topic_0000001166835234_li1849451112587"><a name="ZH-CN_TOPIC_0000001792549964__zh-cn_topic_0000001166835234_li1849451112587"></a><a name="zh-cn_topic_0000001166835234_li1849451112587"></a><span>如果该主机后续会再次安装ProtectAgent，且再次安装ProtectAgent前，主机重新安装过操作系统或者主机的<span class="filepath">“/etc/HostSN/HostSN”</span>文件被删除，则参考以下步骤在管理界面删除主机。否则，请跳过本步骤。</span><p></p>
      <ol type="a">
       <li>选择<span class="uicontrol" id="ZH-CN_TOPIC_0000001792549964__zh-cn_topic_0000001839142377_uicontrol08941439165212">“<span id="ZH-CN_TOPIC_0000001792549964__zh-cn_topic_0000001839142377_text22651956143811">保护</span> &gt; 客户端 &gt; 客户端”</span>。</li>
       <li>按照IP地址查找到已卸载ProtectAgent的主机后，单击<span class="uicontrol">“<span>更多</span> &gt; <span>删除主机</span>”</span>。<p>删除前确保主机未关联SLA。</p></li>
      </ol> <p></p></li>
    </ol>
   </div>
  </div>
 </body>
</html>